package com.bw.zg2.db

import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy.REPLACE
import androidx.room.Query
import androidx.room.Update
import com.bw.zg2.bean.BannerBean
import com.bw.zg2.bean.LoginBean

/**
 *
 * @ClassName: BannerDao
 * @Description: BannerDao,定义Banner表的增删改查操作
 * @Author: zhangyanchao
 * @CreateDate: 2024/9/18 12:05 PM
 * @Version: 1.0
 */
@Dao
interface LoginDao {
    //添加一条数据
    @Insert(onConflict = REPLACE)
    fun insert(bean: LoginBean)


    @Query("select * from login_bean")
    fun getLogin(): LoginBean

    @Update
    fun update(bean: LoginBean)

    @Query("delete from login_bean ")
    fun delete()

}